> Title -> [Port->Eng] (Example: Portuguese to English)
> Shortcut -> Choice
> Macro -> AWeb3:Plugins/FTransAWEB.awebrx 3 (3 is a translation direction)
> Select text for translation
> Go to AREXX Menu and select [Port->Eng]
> Wait for windows with translation :)
ARGS of script
FTransAWEB.awebrx [ARG1] [ARG2]
[ARG1] - Translation direction
0 - English to Francais
1 - English to Deutsch
2 - English to Italiano
3 - English to Portugues
4 - English to Espanol
5 - Francais to English
6 - Deutsch to English
7 - Italiano to English
8 - Espanol to English
9 - Portugues to English
X - To open a request about direction
[ARG2] - %u to send the url to translate or [ALL] to get current
*/
Options Results
tmpfile = "Ram:FTransTmp.AWEB"
tmpclip = "Ram:FTransAWeb.Clip"
sel = ""
u_aweb = ""
Parse Arg traduz u_aweb
u_aweb = space(u_aweb)
/* TESTA SE PODE SER USADAS AS LIBS DO AREXX */
if ~show(l, "rexxsupport.library") then
if ~addlib("rexxsupport.library", 0, -30) then
exit
/* TESTA SE O PROGRAMA JA NAO ESTA COM A PORTA DE TRADUCAO ABERTA */
if exists(tmpfile) then do
janela('"FTranslation port is open! Translation in progress, wait..." "_Ok"')
exit
end
/* COLOCA COMO DEFAULT PORTUGUES TO ENGLISH */
if traduz == '' | traduz == 'X' then do
traduz = requestaweb('"Select your translate direction:*N 1) English to Francais*N 2) English to Deutsch*N 3) English to Italiano*N 4) English to Portugues*N 5) English to Espanol*N 6) Francais to English*N 7) Deutsch to English*N 8) Italiano to English*N 9) Espanol to English*N10) Portugues to English" "1|2|3|4|5|6|7|8|9|10|Quit"')